from django.urls import reverse


def memory_reverse(request, name, *args, **kwargs):
    url = reverse(name, args=args, kwargs=kwargs)
    origin_params = request.GET.get('_filter')
    if origin_params:
        url = '%s?%s' % (url, origin_params)
    return url
